package com.yanmaohu.yulia.bean;

/**
 * @author Bright Lee
 */
public final class MergeWhenMatchedClause implements MergeWhenClause {

    private int beginIndex;
    private int endIndex;
    private MergeUpdateSpecification mergeUpdateSpecification;

    public MergeWhenMatchedClause(int beginIndex,
                                  MergeUpdateSpecification mergeUpdateSpecification) {
        this.beginIndex = beginIndex;
        this.endIndex = mergeUpdateSpecification.getEndIndex();
        this.mergeUpdateSpecification = mergeUpdateSpecification;
    }

    @Override
    public int getBeginIndex() {
        return beginIndex;
    }

    @Override
    public int getEndIndex() {
        return endIndex;
    }

    public MergeUpdateSpecification getMergeUpdateSpecification() {
        return mergeUpdateSpecification;
    }

}
